package containerdepth;

import java.util.HashMap;
import java.util.Map;
import java.util.Random;

public class MyGenerator {
	public transient int m;
	private static Random random = new Random();
	public static class MyByte implements MyGeneratorInf<Byte>{
		@Override
		public Byte next() {
			Byte b = (byte)random.nextInt();
			return b;
		}
		
	}
	private static char[] c= ("00helldkdlakjdkl;ladda1355zcnmm;;i'00").toCharArray();
	public static class MyCharacter implements MyGeneratorInf<Character>{
		private static int count = 0;
		public Character next(){
			return c[count++%c.length];
		}
	}
	public class nonstaticclasstest{
		
	}
	public static class MyTest{
		private static String s;
		public MyTest(String st){
			s = st;
		}
		public void print(){System.out.println(s);}
	}
	public static class MyString implements MyGeneratorInf<String>{
		private char[] s ;
		public MyString(int m){
			s = new char[m];
		}
		public String next(){
			for(int i = 0;i<s.length;i++){
				MyGeneratorInf<Character> mc = new MyCharacter();
				s[i] = mc.next();
			}
			return new String(s);
		}
	}
	public static class MyInteger implements MyGeneratorInf<Integer>{
		public Integer next(){
			return random.nextInt();
		}
	}
	public static class MyMap implements MyGeneratorMapInf<Integer,String>{
		MyString ms = new MyString(10);
		public Map<Integer,String>next(){
			Map<Integer,String> m = new HashMap<Integer,String>();
			m.put(1, ms.next());
			m.put(2, ms.next());
			m.put(3, ms.next());
			m.put(4, ms.next());		
			return m;
		}
	}
	public class MyTest2{
		//you can also create a non-static class in the class
	}
}
